Skip to main content

rms

rms(matrix: any[] | Mat | Tensor) : number

param matrix - an Array, Mat or Tensor, to find the root mean square of.

returns - number - representing the root mean square value

The root mean square is a tool used in a variety of statistical analyses, including but not limited to RMSE (root mean square deviation), variance and more. Overall, it's the square root of the mean in which ech mean variable value is squared. The formula and an example is below:

The root mean square formula is as follows (rms):

$$r = \sqrt{\frac{x_1^2 + ... + x_n^2}{n}}$$